package com.example.demo.Dao;

import org.apache.ibatis.annotations.*;
import org.springframework.stereotype.Repository;

@Mapper
@Repository
public interface ScoreDao {

    @Delete("delete from score where coID=#{coID} and stuID=#{stuID}")
    public void deletescore(String coID,String stuID);

    @Select("select count(*) from score where coID=#{coID} and stuID=#{stuID}")
    public String selectsame(String coID,String stuID);

    @Update("update score set stuscore=#{stuscore} where stuID=#{stuID} and coID=#{coID}")
    public void updateScore(@Param("stuscore") String stuscore,@Param("stuID") String stuID,@Param("coID") String coID);
}
